package com.abigdreamer.im.message;

/**
 * 系统消息 包括 1:消息头 2：系统消息内容
 */
public class SysMessage extends BaseMessage {

	private static final long serialVersionUID = 1L;

	/**
	 * 0:用户好友上线信息 1:用户好友下线信息 2:提醒用户新闻信息
	 */
	private int msgContentType; // 消息内容的类型

	private String sysMsg; // 系统消息内容

	public SysMessage(String srcQQ) {
		this.setMsgType(MessageType.SysMessage_Type);
		this.setSrcQQ(srcQQ);
	}

	public String getSysMsg() {
		return sysMsg;
	}

	public void setSysMsg(String sysMsg) {
		this.sysMsg = sysMsg;
	}

	public int getMsgContentType() {
		return msgContentType;
	}

	public void setMsgContentType(int msgContentType) {
		this.msgContentType = msgContentType;
	}

	public String toString() {
		String str = null;
		if (msgContentType == 0) {
			str = this.getSrcQQ() + "用户好友上线信息";
		} else if (msgContentType == 1) {
			str = this.getSrcQQ() + "用户好友下线信息";
		} else if (msgContentType == 2) {
			str = "提醒用户新闻信息";
		}
		return str;
	}
}
